package beans;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

public class FacturaBean implements Serializable{

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	private Integer nroFactura;
	private List<ItemCartaBean> itemsFactura= new ArrayList<ItemCartaBean>();
	private String estado;
	private float total;
	private Integer nroapmesa;

	
	public FacturaBean() {
		
	}

	public void setItemsCarta(List<ItemCartaBean> itemsCarta) {
		this.itemsFactura = itemsCarta;
	}

	public List<ItemCartaBean> getItemsCarta() {
		return itemsFactura;
	}

	public void setNroFactura(Integer nroFactura) {
		this.nroFactura = nroFactura;
	}

	public Integer getNroFactura() {
		return nroFactura;
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result
				+ ((itemsFactura == null) ? 0 : itemsFactura.hashCode());
		result = prime * result
				+ ((nroFactura == null) ? 0 : nroFactura.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		FacturaBean other = (FacturaBean) obj;
		if (itemsFactura == null) {
			if (other.itemsFactura != null)
				return false;
		} else if (!itemsFactura.equals(other.itemsFactura))
			return false;
		if (nroFactura == null) {
			if (other.nroFactura != null)
				return false;
		} else if (!nroFactura.equals(other.nroFactura))
			return false;
		return true;
	}

	public void setEstado(String estado) {
		this.estado = estado;
	}

	public String getEstado() {
		return estado;
	}

	public void setTotal(float total) {
		this.total = total;
	}

	public float getTotal() {
		return total;
	}

	public void setNroapmesa(Integer nroapmesa) {
		this.nroapmesa = nroapmesa;
	}

	public Integer getNroapmesa() {
		return nroapmesa;
	}


	
}
